home *** CD-ROM | disk | FTP | other *** search
/ Champak 141 / (Vol 141) Oct 17 2011.iso / Games / Clueless.swf / scripts / Forms / UpsellForm.as < prev   
Encoding:
Text File  |  2011-10-17  |  1.2 KB  |  45 lines

  1. package Forms
  2. {
  3.    import flash.events.Event;
  4.    import flash.events.MouseEvent;
  5.    import flash.net.URLRequest;
  6.    import flash.net.navigateToURL;
  7.    import flash.utils.Timer;
  8.    
  9.    [Embed(source="/_assets/assets.swf", symbol="Forms.UpsellForm")]
  10.    public class UpsellForm extends CluelessBaseForm
  11.    {
  12.        
  13.       
  14.       protected var _iSnapshotCountdown:int = 0;
  15.       
  16.       public var _bBuyNow:Button;
  17.       
  18.       protected var _timer:Timer;
  19.       
  20.       public var _bQuit:Button;
  21.       
  22.       protected var _dragcontroller:DragController;
  23.       
  24.       public function UpsellForm()
  25.       {
  26.          _dragcontroller = new DragController();
  27.          _iSnapshotCountdown = 0;
  28.          _timer = new Timer(200,0);
  29.          super();
  30.          _bQuit.addEventListener(MouseEvent.CLICK,onQuit,false,0,true);
  31.          _bBuyNow.addEventListener(MouseEvent.CLICK,onBuyNow,false,0,true);
  32.       }
  33.       
  34.       internal function onBuyNow(param1:Event) : void
  35.       {
  36.          navigateToURL(new URLRequest("http://legacygames.com/download_games/874/clueless/"));
  37.       }
  38.       
  39.       internal function onQuit(param1:Event) : void
  40.       {
  41.          MainDocument.forceQuit();
  42.       }
  43.    }
  44. }
  45.